#!/usr/bin/env python3
# coding: utf-8

import numpy as np
import cv2 as cv

img = np.zeros((500, 500, 3), np.uint8)

# cv2.putText(img, text, org, font, fontScale, color[, thickness[, lineType[, bottomLeftOrigin]]])
font = cv.FONT_HERSHEY_SIMPLEX  # 字体类型
fontScale = 0.5  # 字体大小
font_color = (0, 255, 0)  # 字体颜色
thickness = 1  # 文本的线条粗细，默认值为 1
# cv.putText(img, 'hello opencv', (10,200), font, scale, font_color, thickness, cv.LINE_8)
cv.putText(img, "hello opencv", (10, 200), font, 0.5, (255, 255, 255), 1, cv.LINE_AA)

cv.imshow("img", img)
cv.waitKey(0)
cv.destroyAllWindows()
